isMultiWindowConstrained

fun isMultiWindowConstrained(configuration: Configuration, ignoreMultiWindows: Boolean, context: Context? = null): Boolean

Returns true when the app is in a multi-window mode (split-screen, freeform, PiP) and the caller opted into suppressing scaling via ignoreMultiWindows.

Primary detection uses the public Activity.isInMultiWindowMode API (available since API 24, which matches the library's minSdk). When no Activity can be resolved from the supplied context, a heuristic based on Configuration dimensions is used as a best-effort fallback.

Parameters

context

Optional Context used to resolve the hosting Activity. Pass this whenever available for reliable multi-window detection.